package com.glsc.ngateway.common.base.domain.mysql.gateway.other;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.ToString;
import org.springframework.format.annotation.DateTimeFormat;

import javax.persistence.*;
import java.io.Serializable;

@ToString
@Data
@Entity
@Table(name = "t_am_system_license_module")
public class SystemLicenseModule implements Serializable {

    private static final long serialVersionUID = -2504338726893322494L;

    @ApiModelProperty(value = "子模块")
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "module_id")
    protected Integer moduleId;

    @ApiModelProperty(value = "子模块名称")
    @Column(name = "module_name", columnDefinition = "varchar(100) COMMENT '子模块名称'")
    protected String moduleName;

    @ApiModelProperty(value = "子模块License到期日")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @Column(name = "module_license_expire_date", columnDefinition = "varchar(10) COMMENT '子模块License到期日 yyyy-MM-dd'")
    protected String moduleLicenseExpireDate;

    @ApiModelProperty(value = "所属系统ID")
    @Column(name = "system_id")
    protected Integer systemId;

    @ApiModelProperty(value = "所属系统名称")
    @Transient
    private String systemName;

}
